package ctrls;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

/**
 *
 * @author CDI215
 */
public class SctrlCompte implements ISsCtrl {

    @Override
    public String execute(HttpServletRequest request, HttpServletResponse response) {

        String url = "/WEB-INF/inscription.jsp";


//        if ("compte".equals(request.getParameter("section"))) {
//            url = "/WEB-INF/inscription.jsp";
//
//        }

        if ("compte".equals(request.getParameter("section"))) {
            url = "/WEB-INF/modification.jsp";

        }

        if ("profil".equals(request.getParameter("action"))) {
            url = "/WEB-INF/profil.jsp";
        }
        
        if ("adresses".equals(request.getParameter("action"))) {
            url = "/WEB-INF/adresses.jsp";
        }
        
        if ("telephones".equals(request.getParameter("action"))) {
            url = "/WEB-INF/telephones.jsp";
        }
        
        if ("retour".equals(request.getParameter("action"))) {
            url = "/WEB-INF/modification.jsp";

        }
        
        return url;
    }
}
